//
//  HOTNaviBar.m
//  Genpara
//
//  Created by AndyChang.zhang on 14-8-27.
//  Copyright (c) 2014年 zhangchh. All rights reserved.
//

#import "HOTNaviBar.h"
#import "HOTNavBarViewController.h"

@interface HOTNaviBar () <UINavigationBarDelegate>{
    
    
}

@property(nonatomic,strong)HOTNavBarViewController *naviBarViewController;
@end

@implementation HOTNaviBar

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        
//        self.naviBarViewController = [[HOTNavBarViewController alloc]
//                                      initWithNibName:@"HOTNavBarViewController"
//                                      bundle:nil];
        
        [self setBackgroundImage:[UIImage imageNamed:@"bg_header"] forBarMetrics:UIBarMetricsDefault];
        
    }
    return self;
}


//- (void)drawRect:(CGRect)rect
//{
//    //[self addSubview:self.naviBarViewController.view];
//    //[super drawRect:rect];
//    
//}

//-(void)addBackBtnTarget:(id)target action:(SEL)selector forControlEvents:(UIControlEvents)events {
//    
//    [self.naviBarViewController.backBtn
//     addTarget:target
//     action:selector
//     forControlEvents:events];
//}
//
//-(void)removeBackBtnTarget:(id)target action:(SEL)selector forControlEvents:(UIControlEvents)events {
//    
//    [self.naviBarViewController.backBtn
//     removeTarget:target
//     action:selector
//     forControlEvents:events];
//}
//
//-(void)removeAllTargetsWithBackBtn {
//    
//    NSEnumerator *enumerator = [self.naviBarViewController.backBtn.allTargets objectEnumerator];
//    
//    while (YES) {
//        
//        id target = [enumerator nextObject];
//        
//        if (target) {
//            
//            [self.naviBarViewController.backBtn
//             removeTarget:target
//             action:@selector(backBtnClicked:)
//             forControlEvents:UIControlEventTouchUpInside];
//            
//        } else break;
//    }
//}


@end
